package com.base.service;

import com.base.po.replacement.ReplacementHistory;
import com.base.po.replacement.ReplacementHistoryExample;
import com.base.utils.Page;
import org.apache.ibatis.annotations.Param;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

public interface ReplacementHistoryService {
    int countByExample(ReplacementHistoryExample example);

    int deleteByExample(ReplacementHistoryExample example);

    int insert(ReplacementHistory record);

    int insertSelective(ReplacementHistory record);

    List<ReplacementHistory> selectByExample(ReplacementHistoryExample example);

    List<ReplacementHistory> selectToday(@Param("userid") String userid, @Param("cardno") String cardno,
                                         @Param("createtime") Date createtime);

    List<ReplacementHistory> selectByUserID(@Param("page") Page page, @Param("userid") String userid);

//    int updateByExampleSelective(@Param("record") ReplacementHistory record, @Param("example") ReplacementHistoryExample example);
//
//    int updateByExample(@Param("record") ReplacementHistory record, @Param("example") ReplacementHistoryExample example);

    int countByUserID(String userid);

    BigDecimal selectMoney(@Param("userid")String userid, @Param("cardno")String cardno, @Param("begin") Date begin,
                           @Param("end") Date end);
}